package com.mes.task.manager;

import java.util.List;

import org.hibernate.Session;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.mes.common.condition.Conditions;
import com.mes.common.condition.ConditionObject;
import com.mes.common.condition.ConditionObjectLink;
import com.mes.common.exception.bo.BaseBusinessException;
import com.mes.common.manager.BasicManager;
import com.mes.task.manager.iface.IDemandLinkManager;
import com.mes.task.dao.DemandLinkDao;
import com.mes.task.domain.DemandLink;

@Component
public class DemandLinkManager extends BasicManager<DemandLink> implements IDemandLinkManager {
	
	@Autowired
	private DemandLinkDao demandLinkDao;
	
	public List<DemandLink> getPredDemands(String succDemandUid) throws Exception {
		List demandLinkList = null;
		try {
			demandLinkList = demandLinkDao.findByProperty("succDemandUid", succDemandUid);
		} catch (BaseBusinessException e) {
			e.printStackTrace();
		}
		return demandLinkList;
	}
}
